package com.suyang.syt.model.dto;

import java.util.List;

import com.suyang.syt.model.SystemNavigation;

@SuppressWarnings("serial")
public class SystemNavigationDTO extends SystemNavigation {
	/** 扩展属性,一般是URL地址 */
	private Attributes attributes;
	/** 父菜单 */
	private SystemNavigation parent;
	/** 子菜单集合 */
	private List<SystemNavigationDTO> children;
	
	public SystemNavigationDTO() {
		
	}

	public SystemNavigationDTO(SystemNavigation nav) {
		this.setAttributes(new Attributes(nav.getUrl()));
		this.setChecked(nav.getChecked());
		this.setCode(nav.getCode());
		this.setCreateName(nav.getCreateName());
		this.setCreateTime(nav.getCreateTime());
		this.setIconCls(nav.getIconCls());
		this.setId(nav.getId());
		this.setJianpin(nav.getJianpin());
		this.setQuanpin(nav.getQuanpin());
		this.setLayer(nav.getLayer());
		this.setLeaf(nav.getLeaf());
		this.setModifyName(nav.getModifyName());
		this.setModifyTime(nav.getModifyTime());
		this.setName(nav.getName());
		this.setOrderIndex(nav.getOrderIndex());
		this.setPid(nav.getPid());
		this.setPtext(nav.getPtext());
		this.setState(nav.getState());
		this.setStatus(nav.getStatus());
		this.setText(nav.getText());
		this.setUrl(nav.getUrl());
	}
	
	public Attributes getAttributes() {
		return attributes;
	}

	public void setAttributes(Attributes attributes) {
		this.attributes = attributes;
	}

	public SystemNavigation getParent() {
		return parent;
	}

	public void setParent(SystemNavigation parent) {
		this.parent = parent;
	}

	public List<SystemNavigationDTO> getChildren() {
		return children;
	}

	public void setChildren(List<SystemNavigationDTO> children) {
		this.children = children;
	}

}